<body>
<p>Test that delivering a message to a port that was never referenced from JS doesn't cause a crash.</p>
<pre id=log></pre>
<script src="../../resources/gc.js"></script>
<script>

function log(message)
{
    document.getElementById("log").innerHTML += message + "<br>";
}

if (window.testRunner) {
    testRunner.dumpAsText();
    testRunner.waitUntilDone();
}

var channel = new MessageChannel;
channel.port1.postMessage("msg");
channel.port1.start();
channel = 0;
gc();

setTimeout("log('PASS'); if (window.testRunner) testRunner.notifyDone()", 100);

</script>
</body>
